<%@ page contentType="text/html;charset=UTF-8" language="java" %>

<%@ include file="checkLogin.inc.jsp" %>
<%@ page import="java.util.List" %>
<%@ page import="kulstats.*" %>
<%@ page import="java.util.Map"%>
<%@ page import="java.util.Iterator"%>
<%@ page import="java.util.Set"%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html> 
<head> 
	<title>Home - StAPP</title> 
	
	<%@ include file="mobileResources.inc.jsp" %>
	<!--Load the AJAX API -->
	
</head> 

<body>

<div data-role="page" id="milestonePage">
	<div data-role="header">
		<% WebCache.headerElement = "milestones"; %>
		<%@ include file="mobileHeader.inc.jsp" %>
	</div><!-- /header -->
	
	<div data-role = "content" id = "notSaved" style="display: none;"> 
	<h3>Cannot save Milestone</h3>
	<p id = "par_fail"> </p>
	</div>
	
	<div data-role="content" id="form">
		
	
		<form action="DoMilestone" method="post" id="milestone_form" data-ajax="false">
			<input type="hidden" name="milestone_action" value="milestone_new" />
			
			
			
		<!-- different form objects for each of the setable data of a milestone -->
			<div id="div_mst_course" data-role="fieldcontain">
				<label for="mst_course" class="select">Course:</label>
				<select name="mst_course" id="mst_course">
<%
List<Course> userCourses = currentUser.getCourses();
for(Course c : userCourses) {
	if(c != null) {
%>
					<option value="<%=c.getCourseID() %>"><%=c.getName() %></option>
<%
	}
}
%>
				</select>
			</div>
			
			<div data-role="fieldcontain">
				<label for="hours">Hours:</label>
			 	<input type="range" name="hours" id="hours" value="1" min="1" max="30" />
			</div>
			
			
			<div data-role="button" id="butt_mst_start">Save Milestone</div>
		</form>
		
		<div id='milestones_bars_div'> </div>
		<div id='chart_div'> </div>
		
		<% /*<div id='table'> </div>*/ %>
		
	</div><!-- /content -->
	
	<div data-role="footer">
		<h4>&copy; 2011 - kulStats</h4>
	</div><!-- /footer -->
</div><!-- /page -->


</body>
</html>